home *** CD-ROM | disk | FTP | other *** search
/ System Booster / System Booster.iso / Archives / GNU / ags_000.lha / gs261gdevretina.h < prev    next >
Encoding:
Text File  |  1993-07-15  |  1.3 KB  |  37 lines

  1. typedef struct retina_device_s {
  2.   gx_device_common;
  3.   struct RetinaScreen *rs; /* retina screen pointer */
  4.   ULONG  screenmode;       /* retina screen mode (MID_DEFAULT_*)        */
  5.   gx_color_index ncols;    /* no. of allocated colors (index modes only */
  6.   byte (*palette)[3];  /* color lookup table (index modes only)     */
  7.   float wz_scale_x;
  8.   float wz_scale_y;
  9. } retina_device;
  10.  
  11. #define rdev ((retina_device *)dev)
  12. #define boolean char
  13. #define FALSE 0
  14. #define XPPI 80.0
  15. #define YPPI 75.0
  16. #define SCALE 0.68
  17. #define PRE_WIDTH  800
  18. #define PRE_HEIGHT 600
  19.  
  20. void *AllocMem(unsigned long ,unsigned long );
  21.  
  22. #define RED_BITS    2           /* 2 */
  23. #define GREEN_BITS    RED_BITS    /* 2 */
  24. #define BLUE_BITS    RED_BITS    /* 2 */
  25. #define RGB_BITS    (RED_BITS + GREEN_BITS + BLUE_BITS) /* 6 */
  26. #define MAX_BITS    RED_BITS    /* 2 */
  27. #define BLUE_MASK    ((1<<BLUE_BITS)-1)   
  28. #define GREEN_MASK    ((1<<(BLUE_BITS+GREEN_BITS))-1-BLUE_MASK)
  29. #define RED_MASK    ((1<<(BLUE_BITS+GREEN_BITS+RED_BITS))-1-BLUE_MASK-GREEN_MASK)
  30. #define RED_COLS    (1 << RED_BITS)    /* 4 */
  31. #define GREEN_COLS    (1 << GREEN_BITS)  /* 4 */
  32. #define BLUE_COLS    (1 << BLUE_BITS)   /* 4 */
  33. #define RGB_COLS    (RED_COLS * GREEN_COLS * BLUE_COLS) /* 64 */
  34. #define MAX_COLS    (1 << MAX_BITS) /* max   4 colors/rgb     */
  35. #define ALL_COLS    (1 << 8)    /* max 256 colors in clut */
  36.  
  37.